<!doctype html>



  


<html class="theme-next mist use-motion" lang="zh-Hans">
<head>
  <meta charset="UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"/>



<meta http-equiv="Cache-Control" content="no-transform" />
<meta http-equiv="Cache-Control" content="no-siteapp" />












  
  
  <link href="/lib/fancybox/source/jquery.fancybox.css?v=2.1.5" rel="stylesheet" type="text/css" />




  
  
  
  

  
    
    
  

  

  

  

  

  
    
    
    <link href="//fonts.googleapis.com/css?family=Lato:300,300italic,400,400italic,700,700italic&subset=latin,latin-ext" rel="stylesheet" type="text/css">
  






<link href="/lib/font-awesome/css/font-awesome.min.css?v=4.6.2" rel="stylesheet" type="text/css" />

<link href="/css/main.css?v=5.1.0" rel="stylesheet" type="text/css" />


  <meta name="keywords" content="docker,zookeeper,storm,mesos,dcos,marathon," />








  <link rel="shortcut icon" type="image/x-icon" href="/favicon.ico?v=5.1.0" />






<meta name="description" content="Apache Storm是Twitter开源的分布式实时计算平台。Mesos Storm（以下用“SM”特指Mesos Storm）让Storm框架能够在DCOS集群中部署并使用Mesos为计算拓扑调度资源。">
<meta property="og:type" content="article">
<meta property="og:title" content="Storm on DC/OS(1) - 框架与构建">
<meta property="og:url" content="http://chrisrc.me/2016/12/01/storm-on-dcos-1/index.html">
<meta property="og:site_name" content="山中，山外与俯瞰">
<meta property="og:description" content="Apache Storm是Twitter开源的分布式实时计算平台。Mesos Storm（以下用“SM”特指Mesos Storm）让Storm框架能够在DCOS集群中部署并使用Mesos为计算拓扑调度资源。">
<meta property="og:updated_time" content="2016-12-17T07:15:19.000Z">
<meta name="twitter:card" content="summary">
<meta name="twitter:title" content="Storm on DC/OS(1) - 框架与构建">
<meta name="twitter:description" content="Apache Storm是Twitter开源的分布式实时计算平台。Mesos Storm（以下用“SM”特指Mesos Storm）让Storm框架能够在DCOS集群中部署并使用Mesos为计算拓扑调度资源。">



<script type="text/javascript" id="hexo.configurations">
  var NexT = window.NexT || {};
  var CONFIG = {
    root: '/',
    scheme: 'Mist',
    sidebar: {"position":"left","display":"post"},
    fancybox: true,
    motion: true,
    duoshuo: {
      userId: '0',
      author: '博主'
    },
    algolia: {
      applicationID: '',
      apiKey: '',
      indexName: '',
      hits: {"per_page":10},
      labels: {"input_placeholder":"Search for Posts","hits_empty":"We didn't find any results for the search: ${query}","hits_stats":"${hits} results found in ${time} ms"}
    }
  };
</script>



  <link rel="canonical" href="http://chrisrc.me/2016/12/01/storm-on-dcos-1/"/>





  <title> Storm on DC/OS(1) - 框架与构建 | 山中，山外与俯瞰 </title>
</head>

<body itemscope itemtype="http://schema.org/WebPage" lang="zh-Hans">

  










  
  
    
  

  <div class="container one-collumn sidebar-position-left page-post-detail ">
    <div class="headband"></div>

    <header id="header" class="header" itemscope itemtype="http://schema.org/WPHeader">
      <div class="header-inner"><div class="site-meta ">
  

  <div class="custom-logo-site-title">
    <a href="/"  class="brand" rel="start">
      <span class="logo-line-before"><i></i></span>
      <span class="site-title">山中，山外与俯瞰</span>
      <span class="logo-line-after"><i></i></span>
    </a>
  </div>
  <p class="site-subtitle">一次永不停止的探索之旅</p>
</div>

<div class="site-nav-toggle">
  <button>
    <span class="btn-bar"></span>
    <span class="btn-bar"></span>
    <span class="btn-bar"></span>
  </button>
</div>

<nav class="site-nav">
  

  
    <ul id="menu" class="menu">
      
        
        <li class="menu-item menu-item-home">
          <a href="/" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-home"></i> <br />
            
            首页
          </a>
        </li>
      
        
        <li class="menu-item menu-item-dcos">
          <a href="/dcos" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-book"></i> <br />
            
            DC/OS
          </a>
        </li>
      
        
        <li class="menu-item menu-item-categories">
          <a href="/categories" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-th"></i> <br />
            
            分类
          </a>
        </li>
      
        
        <li class="menu-item menu-item-about">
          <a href="/about" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-user"></i> <br />
            
            关于
          </a>
        </li>
      
        
        <li class="menu-item menu-item-archives">
          <a href="/archives" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-archive"></i> <br />
            
            归档
          </a>
        </li>
      
        
        <li class="menu-item menu-item-tags">
          <a href="/tags" rel="section">
            
              <i class="menu-item-icon fa fa-fw fa-tags"></i> <br />
            
            标签
          </a>
        </li>
      

      
        <li class="menu-item menu-item-search">
          
            <a href="javascript:;" class="st-search-show-outputs">
          
            
              <i class="menu-item-icon fa fa-search fa-fw"></i> <br />
            
            搜索
          </a>
        </li>
      
    </ul>
  

  
    <div class="site-search">
      
  <form class="site-search-form">
  <input type="text" id="st-search-input" class="st-search-input st-default-search-input" />
</form>

<script type="text/javascript">
  (function(w,d,t,u,n,s,e){w['SwiftypeObject']=n;w[n]=w[n]||function(){
    (w[n].q=w[n].q||[]).push(arguments);};s=d.createElement(t);
    e=d.getElementsByTagName(t)[0];s.async=1;s.src=u;e.parentNode.insertBefore(s,e);
  })(window,document,'script','//s.swiftypecdn.com/install/v2/st.js','_st');

  _st('install', 'R9GcmhBwxpsAGLNCsquZ','2.0.0');
</script>



    </div>
  
</nav>



 </div>
    </header>

    <main id="main" class="main">
      <div class="main-inner">
        <div class="content-wrap">
          <div id="content" class="content">
            

  <div id="posts" class="posts-expand">
    

  

  
  
  

  <article class="post post-type-normal " itemscope itemtype="http://schema.org/Article">
  <link itemprop="mainEntityOfPage" href="http://chrisrc.me/2016/12/01/storm-on-dcos-1/">

  <span style="display:none" itemprop="author" itemscope itemtype="http://schema.org/Person">
    <meta itemprop="name" content="chrisrc">
    <meta itemprop="description" content="">
    <meta itemprop="image" content="/images/avatar.gif">
  </span>

  <span style="display:none" itemprop="publisher" itemscope itemtype="http://schema.org/Organization">
    <meta itemprop="name" content="山中，山外与俯瞰">
    <span style="display:none" itemprop="logo" itemscope itemtype="http://schema.org/ImageObject">
      <img style="display:none;" itemprop="url image" alt="山中，山外与俯瞰" src="">
    </span>
  </span>

    
      <header class="post-header">

        
        
          <h1 class="post-title" itemprop="name headline">
            
            
              
                Storm on DC/OS(1) - 框架与构建
              
            
          </h1>
        

        <div class="post-meta">
          <span class="post-time">
            
              <span class="post-meta-item-icon">
                <i class="fa fa-calendar-o"></i>
              </span>
              <span class="post-meta-item-text">发表于</span>
              <time title="Post created" itemprop="dateCreated datePublished" datetime="2016-12-01T17:10:18+08:00">
                2016-12-01
              </time>
            

            

            
          </span>

          
            <span class="post-category" >
              <span class="post-meta-divider">|</span>
              <span class="post-meta-item-icon">
                <i class="fa fa-folder-o"></i>
              </span>
              <span class="post-meta-item-text">分类于</span>
              
                <span itemprop="about" itemscope itemtype="http://schema.org/Thing">
                  <a href="/categories/DC-OS/" itemprop="url" rel="index">
                    <span itemprop="name">DC/OS</span>
                  </a>
                </span>

                
                
              
            </span>
          

          
            
              <span class="post-comments-count">
                <span class="post-meta-divider">|</span>
                <a href="/2016/12/01/storm-on-dcos-1/#comments" itemprop="discussionUrl">
                  <span class="post-comments-count ds-thread-count" data-thread-key="2016/12/01/storm-on-dcos-1/" itemprop="commentCount"></span>
                </a>
              </span>
            
          

          

          
          

          

          

        </div>
      </header>
    


    <div class="post-body" itemprop="articleBody">

      
      

      
        <p><a href="http://storm.apache.org" target="_blank" rel="external">Apache Storm</a>是Twitter开源的分布式实时计算平台。<a href="https://github.com/mesos/storm" target="_blank" rel="external">Mesos Storm</a>（以下用“<strong>SM</strong>”特指Mesos Storm）让Storm框架能够在DCOS集群中部署并使用Mesos为计算拓扑调度资源。<br><a id="more"></a></p>
<h3 id="在DC-OS上运行Storm"><a href="#在DC-OS上运行Storm" class="headerlink" title="在DC/OS上运行Storm"></a>在DC/OS上运行Storm</h3><p>Storm有自己一套独立的计算作业调度管理机制。Storm通过Nimbus管理Supervisor节点，计算作业（Topology）通过Nimbus部署到Supervisor节点上，然后根据拓扑配置启动相应的Worker（JVM）进程处理作业任务。在一个Supervisor节点上可以启动多个Worker，每个Worker对应一个WorkerSlot，它是由Host和Port及对应的资源配置组成。</p>
<p>Storm的上述拓扑调度机制与Mesos的资源调度非常相似，Mesos向框架提供计算资源，框架的Scheduler接收资源并在分配的资源上通过Executor启动任务。</p>
<p>因此，为实现Storm框架使用Mesos提供的计算资源，Mesos Storm重写了Storm提供的INimbus和IScheduler接口。</p>
<p><strong>INimbus接口：</strong></p>
<figure class="highlight java"><table><tr><td class="gutter"><pre><div class="line">1</div><div class="line">2</div><div class="line">3</div><div class="line">4</div><div class="line">5</div><div class="line">6</div><div class="line">7</div><div class="line">8</div><div class="line">9</div><div class="line">10</div><div class="line">11</div><div class="line">12</div><div class="line">13</div><div class="line">14</div><div class="line">15</div><div class="line">16</div><div class="line">17</div><div class="line">18</div><div class="line">19</div><div class="line">20</div><div class="line">21</div><div class="line">22</div><div class="line">23</div><div class="line">24</div><div class="line">25</div></pre></td><td class="code"><pre><div class="line"><span class="keyword">public</span> <span class="class"><span class="keyword">interface</span> <span class="title">INimbus</span> </span>&#123;</div><div class="line"><span class="function"><span class="keyword">void</span> <span class="title">prepare</span><span class="params">(Map stormConf, String schedulerLocalDir)</span></span>;</div><div class="line"><span class="comment">/**</span></div><div class="line">* Returns all slots that are available for the next round of scheduling. A slot is available for scheduling</div><div class="line">* if it is free and can be assigned to, or if it is used and can be reassigned.</div><div class="line">*/</div><div class="line"><span class="function">Collection&lt;WorkerSlot&gt; <span class="title">allSlotsAvailableForScheduling</span><span class="params">(Collection&lt;SupervisorDetails&gt; existingSupervisors, Topologies topologies, Set&lt;String&gt; topologiesMissingAssignments)</span></span>;</div><div class="line"></div><div class="line"></div><div class="line"><span class="comment">/**</span></div><div class="line">* this is called after the assignment is changed in ZK</div><div class="line">* <span class="doctag">@param</span> topologies</div><div class="line">* <span class="doctag">@param</span> newSlotsByTopologyId</div><div class="line">*/</div><div class="line"><span class="function"><span class="keyword">void</span> <span class="title">assignSlots</span><span class="params">(Topologies topologies, Map&lt;String, Collection&lt;WorkerSlot&gt;&gt; newSlotsByTopologyId)</span></span>;</div><div class="line"></div><div class="line"><span class="comment">/**</span></div><div class="line">* map from node id to supervisor details</div><div class="line">* <span class="doctag">@param</span> existingSupervisors</div><div class="line">* <span class="doctag">@param</span> nodeId</div><div class="line">* <span class="doctag">@return</span></div><div class="line">*/</div><div class="line"><span class="function">String <span class="title">getHostName</span><span class="params">(Map&lt;String, SupervisorDetails&gt; existingSupervisors, String nodeId)</span></span>;</div><div class="line"><span class="function">IScheduler <span class="title">getForcedScheduler</span><span class="params">()</span></span>;</div><div class="line">&#125;</div></pre></td></tr></table></figure>
<p><strong>IScheduler接口：</strong></p>
<figure class="highlight java"><table><tr><td class="gutter"><pre><div class="line">1</div><div class="line">2</div><div class="line">3</div><div class="line">4</div><div class="line">5</div><div class="line">6</div><div class="line">7</div><div class="line">8</div><div class="line">9</div><div class="line">10</div><div class="line">11</div><div class="line">12</div><div class="line">13</div><div class="line">14</div><div class="line">15</div><div class="line">16</div></pre></td><td class="code"><pre><div class="line"><span class="keyword">public</span> <span class="class"><span class="keyword">interface</span> <span class="title">IScheduler</span> </span>&#123;</div><div class="line"><span class="function"><span class="keyword">void</span> <span class="title">prepare</span><span class="params">(Map conf)</span></span>;</div><div class="line"><span class="comment">/**</span></div><div class="line">* Set assignments for the topologies which needs scheduling. The new assignments is available</div><div class="line">* through `cluster.getAssignments()`</div><div class="line">*</div><div class="line">*<span class="doctag">@param</span> topologies all the topologies in the cluster, some of them need schedule. Topologies object here</div><div class="line">* only contain static information about topologies. Information like assignments, slots are all in</div><div class="line">* the `cluster` object.</div><div class="line">*<span class="doctag">@param</span> cluster the cluster these topologies are running in. `cluster` contains everything user</div><div class="line">* need to develop a new scheduling logic. e.g. supervisors information, available slots, current</div><div class="line">* assignments for all the topologies etc. User can set the new assignment for topologies using</div><div class="line">* cluster.setAssignmentById()`</div><div class="line">*/</div><div class="line"><span class="function"><span class="keyword">void</span> <span class="title">schedule</span><span class="params">(Topologies topologies, Cluster cluster)</span></span>;</div><div class="line">&#125;</div></pre></td></tr></table></figure>
<p>在代码中，MesosNimbus实现INimbus接口，向Mesos Master注册并接收Mesos提供的资源。当接收到拓扑部署请求时，它向IMesosStormScheduler接口的实现获取所有可用于处理该拓扑的WorkerSlot。</p>
<p><strong>IMesosStormScheduler接口：</strong></p>
<figure class="highlight java"><table><tr><td class="gutter"><pre><div class="line">1</div><div class="line">2</div><div class="line">3</div><div class="line">4</div><div class="line">5</div><div class="line">6</div><div class="line">7</div><div class="line">8</div><div class="line">9</div><div class="line">10</div><div class="line">11</div><div class="line">12</div><div class="line">13</div><div class="line">14</div><div class="line">15</div><div class="line">16</div></pre></td><td class="code"><pre><div class="line"><span class="comment">/**</span></div><div class="line">* A scheduler needs to implement the following interface for it to be MesosNimbus compatible.</div><div class="line">*/</div><div class="line"><span class="keyword">public</span> <span class="class"><span class="keyword">interface</span> <span class="title">IMesosStormScheduler</span> </span>&#123;</div><div class="line"></div><div class="line"><span class="comment">/**</span></div><div class="line">* This method is invoked by Nimbus when it wants to get a list of worker slots that are available for assigning the</div><div class="line">* topology workers. In Nimbus's view, a "WorkerSlot" is a host and port that it can use to assign a worker.</div><div class="line">* &lt;p/&gt;</div><div class="line">* <span class="doctag">TODO:</span> Rotating Map itself needs to be refactored. Perhaps make RotatingMap inherit Map so users can pass in a</div><div class="line">* map? or Make the IMesosStormScheduler itself generic so _offers could be of any type?</div><div class="line">*/</div><div class="line"><span class="function"><span class="keyword">public</span> List&lt;WorkerSlot&gt; <span class="title">allSlotsAvailableForScheduling</span><span class="params">(RotatingMap&lt;Protos.OfferID, Protos.Offer&gt; offers,</span></span></div><div class="line">Collection&lt;SupervisorDetails&gt; existingSupervisors,</div><div class="line">Topologies topologies, Set&lt;String&gt; topologiesMissingAssignments);</div><div class="line">&#125;</div></pre></td></tr></table></figure>
<p>IMesosStormScheduler接口的实现DefaultScheduler同时实现了IScheduler接口，它负责根据拓扑的请求信息以及Mesos提供的资源，生成特定于拓扑的MesosWorkerSlot。</p>
<p>Storm框架仅对WorkerSlot有认知，因此MesosWorkerSlot继承自WorkerSlot又稍有差别：</p>
<ul>
<li><p>不同的拓扑对CPU和内存的资源需求不同，MesosWorkerSlot根据拓扑信息创建，只属于该特定拓扑，不能用于为其它拓扑启动Worker。</p>
</li>
<li><p>MesosNimbus为拓扑调度资源时，DefaultScheduler可以提前获知拓扑的信息，为其分配MesosWorkerSlot并将分配信息保存到mesosWorkerSlotMap，在Storm后续调用schedule时，可以直接从mesosWorkerSlotMap中获取可用的slot。</p>
</li>
<li><p>当前Storm在调用schedule方法时，每次都会传入新创建的WorkerSlot实例，因此需要mesosWorkerSlotMap暂存基于Mesos的Slot调度实例信息。</p>
</li>
</ul>
<h3 id="编译"><a href="#编译" class="headerlink" title="编译"></a>编译</h3><p>从<a href="http://github.com/christtrc/storm" target="_blank" rel="external">Github仓库</a>下载源代码。</p>
<p>Mesos Storm支持独立打包和镜像打包两种方式。本文重点关注镜像打包（以及后续在DC/OS中部署）方式。在编写本文时，官方仓库中默认的配置为：</p>
<ul>
<li>JDK 7</li>
<li>Storm 1.0.2</li>
<li>Mesos 0.27.0</li>
</ul>
<p>为适应DC/OS的部署，<a href="https://github.com/christtrc/storm" target="_blank" rel="external">本仓库</a>对上述配置及部分Dockerfile的内容进行了调整(JDK替换为Oracle JDK，时区及locale等），目前配置为：</p>
<ul>
<li>JDK 8</li>
<li>Storm 1.0.2</li>
<li>Mesos 1.1.0</li>
</ul>
<p>同时，支持为Executor容器镜像提供Volume存储。</p>
<p>也可以在编译镜像时指定版本信息：</p>
<figure class="highlight plain"><table><tr><td class="gutter"><pre><div class="line">1</div></pre></td><td class="code"><pre><div class="line">make images STORM_RELEASE=1.0.2 MESOS_RELEASE=1.1.0 JAVA_PRODUCT_VERSION=8 DOCKER_REPO=chrisrc/storm</div></pre></td></tr></table></figure>
<p>编译构建镜像时有几个重要的文件需要引起注意：</p>
<ul>
<li>storm.yaml</li>
</ul>
<p>这个文件中的配置会被打包到Docker镜像中，可以在运行时通过Docker的Volume挂载加载外部storm.yaml定义。</p>
<ul>
<li><p>Dockerfile<br>这个文件定义了镜像的打包脚本，可以根据需要调整。</p>
</li>
<li><p>bin/run-with-marathon.sh<br>这个文件用于在DC/OS中通过Marathon启动Storm Nimbus及UI。</p>
</li>
</ul>
<h3 id="运行"><a href="#运行" class="headerlink" title="运行"></a>运行</h3><p>如果成功编译了容器镜像，且存在Mesos集群并正确配置（关于配置可参考后面章节），则可以通过下述命令启动Nimbus及UI：</p>
<p><strong>Nimbus：</strong></p>
<figure class="highlight plain"><table><tr><td class="gutter"><pre><div class="line">1</div></pre></td><td class="code"><pre><div class="line">docker run -it chrisrc/storm:0.2.1-SNAPSHOT-1.0.2-1.1.0-jdk8 bin/storm-mesos nimbus</div></pre></td></tr></table></figure>
<p><strong>UI：</strong></p>
<figure class="highlight plain"><table><tr><td class="gutter"><pre><div class="line">1</div></pre></td><td class="code"><pre><div class="line">docker run -it chrisrc/storm:0.2.1-SNAPSHOT-1.0.2-1.1.0-jdk8 bin/storm ui</div></pre></td></tr></table></figure>
<p>向Storm/Mesos集群部署拓扑与向传统的Storm集群部署拓扑的方式完全相同，请参考后续示例。</p>
<p>Storm/Mesos支持在Vagrant中运行，详细信息请参考<a href="https://github.com/christtrc/storm/blob/master/docs/vagrant.md" target="_blank" rel="external">文档</a>。</p>

      
    </div>

    <div>
      
        

      
    </div>

    <div>
      
        

      
    </div>


    <footer class="post-footer">
      
        <div class="post-tags">
          
            <a href="/tags/docker/" rel="tag"># docker</a>
          
            <a href="/tags/zookeeper/" rel="tag"># zookeeper</a>
          
            <a href="/tags/storm/" rel="tag"># storm</a>
          
            <a href="/tags/mesos/" rel="tag"># mesos</a>
          
            <a href="/tags/dcos/" rel="tag"># dcos</a>
          
            <a href="/tags/marathon/" rel="tag"># marathon</a>
          
        </div>
      

      
        <div class="post-nav">
          <div class="post-nav-next post-nav-item">
            
              <a href="/2016/11/28/dcos-book-step-by-step/" rel="next" title="DC/OS修炼之路">
                <i class="fa fa-chevron-left"></i> DC/OS修炼之路
              </a>
            
          </div>

          <span class="post-nav-divider"></span>

          <div class="post-nav-prev post-nav-item">
            
              <a href="/2016/12/03/storm-on-dcos-2/" rel="prev" title="Storm on DC/OS(2) - 集群配置">
                Storm on DC/OS(2) - 集群配置 <i class="fa fa-chevron-right"></i>
              </a>
            
          </div>
        </div>
      

      
      
    </footer>
  </article>



    <div class="post-spread">
      
        <div class="ds-share flat" data-thread-key="2016/12/01/storm-on-dcos-1/"
     data-title="Storm on DC/OS(1) - 框架与构建"
     data-content=""
     data-url="http://chrisrc.me/2016/12/01/storm-on-dcos-1/">
  <div class="ds-share-inline">
    <ul  class="ds-share-icons-16">

      <li data-toggle="ds-share-icons-more"><a class="ds-more" href="javascript:void(0);">分享到：</a></li>
      <li><a class="ds-weibo" href="javascript:void(0);" data-service="weibo">微博</a></li>
      <li><a class="ds-qzone" href="javascript:void(0);" data-service="qzone">QQ空间</a></li>
      <li><a class="ds-qqt" href="javascript:void(0);" data-service="qqt">腾讯微博</a></li>
      <li><a class="ds-wechat" href="javascript:void(0);" data-service="wechat">微信</a></li>

    </ul>
    <div class="ds-share-icons-more">
    </div>
  </div>
</div>
      
    </div>
  </div>


          </div>
          


          
  <div class="comments" id="comments">
    
      <div class="ds-thread" data-thread-key="2016/12/01/storm-on-dcos-1/"
           data-title="Storm on DC/OS(1) - 框架与构建" data-url="http://chrisrc.me/2016/12/01/storm-on-dcos-1/">
      </div>
    
  </div>


        </div>
        
          
  
  <div class="sidebar-toggle">
    <div class="sidebar-toggle-line-wrap">
      <span class="sidebar-toggle-line sidebar-toggle-line-first"></span>
      <span class="sidebar-toggle-line sidebar-toggle-line-middle"></span>
      <span class="sidebar-toggle-line sidebar-toggle-line-last"></span>
    </div>
  </div>

  <aside id="sidebar" class="sidebar">
    <div class="sidebar-inner">

      

      
        <ul class="sidebar-nav motion-element">
          <li class="sidebar-nav-toc sidebar-nav-active" data-target="post-toc-wrap" >
            文章目录
          </li>
          <li class="sidebar-nav-overview" data-target="site-overview">
            站点概览
          </li>
        </ul>
      

      <section class="site-overview sidebar-panel">
        <div class="site-author motion-element" itemprop="author" itemscope itemtype="http://schema.org/Person">
          <img class="site-author-image" itemprop="image"
               src="/images/avatar.gif"
               alt="chrisrc" />
          <p class="site-author-name" itemprop="name">chrisrc</p>
          <p class="site-description motion-element" itemprop="description"></p>
        </div>
        <nav class="site-state motion-element">
          <div class="site-state-item site-state-posts">
            <a href="/archives">
              <span class="site-state-item-count">69</span>
              <span class="site-state-item-name">日志</span>
            </a>
          </div>

          
            <div class="site-state-item site-state-categories">
              <a href="/categories">
                <span class="site-state-item-count">21</span>
                <span class="site-state-item-name">分类</span>
              </a>
            </div>
          

          
            <div class="site-state-item site-state-tags">
              <a href="/tags">
                <span class="site-state-item-count">162</span>
                <span class="site-state-item-name">标签</span>
              </a>
            </div>
          

        </nav>

        

        <div class="links-of-author motion-element">
          
            
              <span class="links-of-author-item">
                <a href="https://github.com/christtrc" target="_blank" title="GitHub">
                  
                    <i class="fa fa-fw fa-github"></i>
                  
                  GitHub
                </a>
              </span>
            
              <span class="links-of-author-item">
                <a href="https://twitter.com/chrisrc" target="_blank" title="Twitter">
                  
                    <i class="fa fa-fw fa-twitter"></i>
                  
                  Twitter
                </a>
              </span>
            
          
        </div>

        
        
          <div class="cc-license motion-element" itemprop="license">
            <a href="https://creativecommons.org/licenses/by-nc-sa/4.0/" class="cc-opacity" target="_blank">
              <img src="/images/cc-by-nc-sa.svg" alt="Creative Commons" />
            </a>
          </div>
        

        
        

        


      </section>

      
      <!--noindex-->
        <section class="post-toc-wrap motion-element sidebar-panel sidebar-panel-active">
          <div class="post-toc">

            
              
            

            
              <div class="post-toc-content"><ol class="nav"><li class="nav-item nav-level-3"><a class="nav-link" href="#在DC-OS上运行Storm"><span class="nav-number">1.</span> <span class="nav-text">在DC/OS上运行Storm</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#编译"><span class="nav-number">2.</span> <span class="nav-text">编译</span></a></li><li class="nav-item nav-level-3"><a class="nav-link" href="#运行"><span class="nav-number">3.</span> <span class="nav-text">运行</span></a></li></ol></div>
            

          </div>
        </section>
      <!--/noindex-->
      

    </div>
  </aside>


        
      </div>
    </main>

    <footer id="footer" class="footer">
      <div class="footer-inner">
        <div class="copyright" >
  
  &copy;  2015 - 
  <span itemprop="copyrightYear">2017</span>
  <span class="with-love">
    <i class="fa fa-heart"></i>
  </span>
  <span class="author" itemprop="copyrightHolder">
     
      <a href="mailto:chrisrc@qq.com">chrisrc</a> 
    
  </span>
  <span class="author"> &nbsp; QQ: 58122705 </span>
</div>


<div class="powered-by">
  由 <a class="theme-link" href="https://hexo.io">Hexo</a> 强力驱动
</div>

<div class="theme-info">
  主题 -
  <a class="theme-link" href="https://github.com/iissnan/hexo-theme-next">
    NexT.Mist
  </a>
</div>


        

        
      </div>
    </footer>

    <div class="back-to-top">
      <i class="fa fa-arrow-up"></i>
    </div>
  </div>

  

<script type="text/javascript">
  if (Object.prototype.toString.call(window.Promise) !== '[object Function]') {
    window.Promise = null;
  }
</script>









  



  
  <script type="text/javascript" src="/lib/jquery/index.js?v=2.1.3"></script>

  
  <script type="text/javascript" src="/lib/fastclick/lib/fastclick.min.js?v=1.0.6"></script>

  
  <script type="text/javascript" src="/lib/jquery_lazyload/jquery.lazyload.js?v=1.9.7"></script>

  
  <script type="text/javascript" src="/lib/velocity/velocity.min.js?v=1.2.1"></script>

  
  <script type="text/javascript" src="/lib/velocity/velocity.ui.min.js?v=1.2.1"></script>

  
  <script type="text/javascript" src="/lib/fancybox/source/jquery.fancybox.pack.js?v=2.1.5"></script>


  


  <script type="text/javascript" src="/js/src/utils.js?v=5.1.0"></script>

  <script type="text/javascript" src="/js/src/motion.js?v=5.1.0"></script>



  
  

  
  <script type="text/javascript" src="/js/src/scrollspy.js?v=5.1.0"></script>
<script type="text/javascript" src="/js/src/post-details.js?v=5.1.0"></script>



  


  <script type="text/javascript" src="/js/src/bootstrap.js?v=5.1.0"></script>



  

  
    
  

  <script type="text/javascript">
    var duoshuoQuery = {short_name:"chrisrc"};
    (function() {
      var ds = document.createElement('script');
      ds.type = 'text/javascript';ds.async = true;
      ds.id = 'duoshuo-script';
      ds.src = (document.location.protocol == 'https:' ? 'https:' : 'http:') + '//static.duoshuo.com/embed.js';
      ds.charset = 'UTF-8';
      (document.getElementsByTagName('head')[0]
      || document.getElementsByTagName('body')[0]).appendChild(ds);
    })();
  </script>

  
    
    
    <script src="/lib/ua-parser-js/dist/ua-parser.min.js?v=0.7.9"></script>
    <script src="/js/src/hook-duoshuo.js"></script>
  








  
  

  

  

  
<script>
(function(){
    var bp = document.createElement('script');
    var curProtocol = window.location.protocol.split(':')[0];
    if (curProtocol === 'https') {
        bp.src = 'https://zz.bdstatic.com/linksubmit/push.js';        
    }
    else {
        bp.src = 'http://push.zhanzhang.baidu.com/push.js';
    }
    var s = document.getElementsByTagName("script")[0];
    s.parentNode.insertBefore(bp, s);
})();
</script>


  
<script>
(function(){
   var src = (document.location.protocol == "http:") ? "http://js.passport.qihucdn.com/11.0.1.js?ed903ab05fbc5fa64d95e4bfbf3d3a04":"https://jspassport.ssl.qhimg.com/11.0.1.js?ed903ab05fbc5fa64d95e4bfbf3d3a04";
   document.write('<script src="' + src + '" id="sozz"><\/script>');
})();
</script>

  


</body>
</html>
